home *** CD-ROM | disk | FTP | other *** search
/ Nebula 2 / Nebula Two.iso / NextAnswers / 1492_NFS_Performance_Tuning.rtfd / TXT.rtf < prev   
Text File  |  1995-06-12  |  24KB  |  702 lines

  1. {\rtf0\ansi{\fonttbl\f2\fnil Times-Roman;\f3\ftech Symbol;\f0\fswiss Helvetica;}
  2. \paperw11660
  3. \paperh12920
  4. \margl120
  5. \margr0
  6. {\colortbl;\red0\green0\blue0;}
  7. \f2\b0\i\ulnone\ql\fs24\fi0\li0\gray0\fc0\cf0\up0\dn0 NEXTSTEP In Focus
  8. \i0 , Fall 1993 (Volume 3, Issue 4). \
  9. Copyright 
  10. \f3 ª
  11. \f2 1993 by NeXT Computer, Inc.  All Rights Reserved.\
  12. \
  13.  
  14. \fs16 \
  15.  
  16. \fs94 NFS Performance Tuning\
  17.  
  18. \fs16 \
  19.  
  20. \pard\tx7500\tx9520\fs28\fc0\cf0 Wayde Schroeder\
  21.  
  22. \fs16 \
  23.  
  24. \i\fs28 Tuning NFS to work efficiently can both increase the speed at which you access NFS-mounted files and decrease the load on your network. This article explains the NFS tuning parameters you can set and shows you how to optimize the performance of Ethernet adapters on Intel-based PCs.\
  25.  
  26. \fs16 \
  27. \
  28.  
  29. \pard\f0\b\i0\fc0\cf0 \
  30. \
  31.  
  32. \fs48 Overview\
  33.  
  34. \fs16 \
  35.  
  36. \pard\tx7500\tx9520\f2\b0\fs28\fc0\cf0 The Network File System (NFS) allows a local computer to access files on another computer, as if the files were on the local computer's disk. Because most home directories and applications reside on NFS-mounted file systems, improving NFS performance on a network can make a big difference in user productivity. \
  37.  
  38. \fs16 \
  39.  
  40. \fs28 This article explains how to tune two basic NFS operations. It also compares the performance of the three Ethernet adapters currently available for use with NEXTSTEP, and shows how to get the best performance from each.\
  41.  
  42. \fs16 \
  43.  
  44. \pard\f0\b\fc0\cf0 \
  45. \
  46. \
  47.  
  48. \fs48 NFS tuning parameters\
  49.  
  50. \fs16 \
  51.  
  52. \pard\tx7500\tx9520\f2\b0\fs28\fc0\cf0 You can tune two aspects of NFS operation: How an NFS server is mounted and how the client and server communicate. All tuning parameters must be specified by the initial mount command. \
  53.  
  54. \fs16 \
  55.  
  56. \fs28 The most important tuning parameters are 
  57. \b rsize
  58. \b0  and 
  59. \b wsize
  60. \b0 . They control the sizes of the NFS read and write buffers, and therefore directly affect how long reading and writing take. For some networks, 
  61. \b timeo
  62. \b0  and 
  63. \b retrans
  64. \b0  are also important. The other parameters give you finer control over how to initiate mounts, what to do if communication fails, and what information to cache.\
  65.  
  66. \fs16 \
  67.  
  68. \fs28 Here's how to tune both NFS mounting and client/server communication.\
  69.  
  70. \fs16 \
  71.  
  72. \f0\b \
  73.  
  74. \fs28 Mounting the server\
  75.  
  76. \fs16 \
  77.  
  78. \f2\b0\fs28 There are three ways to initiate an NFS mount: The client can request a mount when its host computer starts up, the client can request a mount automatically with the 
  79. \b autonfsmount
  80. \b0  command when the remote file system is needed, or you can mount a remote file system by hand using the 
  81. \b mount
  82. \b0  command. \
  83.  
  84. \fs16 \
  85.  
  86. \fs28 When and how to use each method are covered in detail in “Techniques for Using the Network File System” (
  87. \i support bulletin 1
  88. \i0 , Summer 1991), so I won't explain it all here. What's important for this article is the fact that you tune NFS mounting the same way, no matter which mount method you use.\
  89.  
  90. \fs16 \
  91.  
  92. \fs28 The mount tuning parameters affect how the communication between the NFS client and the server is initiated. To initiate a mount, the client sends a request to a server. The server checks the access rights of the directory that the client wants to mount and the access rights of the client itself. If the server's NetInfo
  93. \f3\fs20\up6 î 
  94. \f2\fs28\up0 database shows that the client is allowed access, the server sends the client an NFS file handle, which points to the mounted directory. \
  95.  
  96. \fs16 \
  97.  
  98. \pard\fc0\cf0 \
  99.  
  100. \pard\tx7500\tx9520\i\fs24\fc0\cf0 Note: To find out more about NFS access rights, see the UNIX manual page on 
  101. \b exportfs
  102. \b0 .\
  103.  
  104. \i0\fs28 \
  105.  
  106. \pard\tx7660\tx9660\f0\b\i\fs16\fc0\cf0 \
  107.  
  108. \fs24 Mounting options\
  109.  
  110. \fs16 \
  111.  
  112. \pard\tx7500\tx9520\f2\b0\i0\fs28\fc0\cf0 You tune the mounting process by setting how long the client waits for the server to reply and how many times the client retries. You can also specify whether the client should run the retry process in the background or foreground. Retrying in the background allows the client to run other tasks while waiting; retrying in the foreground causes it to just wait for a response. Foreground retries are only useful if the client can't operate without the mount. \
  113.  
  114. \fs16 \
  115.  
  116. \pard\tx2160\tx9520\f0\b\fs24\fi-1800\li2160\fc1\cf1 Parameter    Use\
  117. fg
  118. \b0  or 
  119. \b bg
  120. \b0     Determines whether retries run in the foreground or background. Default is 
  121. \b fg
  122. \b0 . \
  123.  
  124. \pard\tx100\f2\i\fs16\fc0\cf0 \
  125.  
  126. \pard\tx2160\tx9520\f0\b\i0\fs24\fi-1800\li2160\fc1\cf1 mnttimeo
  127. \b0     Sets how many seconds the client waits for a response for the server before retrying. Default is 20 seconds.\
  128.  
  129. \pard\tx100\f2\i\fs16\fc0\cf0 \
  130.  
  131. \pard\tx2160\tx9520\f0\b\i0\fs24\fi-1800\li2160\fc1\cf1 retry
  132. \b0     Sets the number of times the client retries a mount request before giving up. Default is 1 time.\
  133.  
  134. \pard\tx100\f2\i\fs16\fc0\cf0 \
  135.  
  136. \f0\b\i0\fs24 Figure 1:  
  137. \f2\b0\i Parameters for tuning NFS mounts\
  138.  
  139. \fs16 \
  140.  
  141. \pard\tx7500\tx9520\i0\fs28\fc0\cf0 For example, Figure 2 shows settings for mounting a directory on client 
  142. \b eng
  143. \b0 . The client waits 30 seconds for a response from the NFS server. If it doesn't get a response, it retries in the background up to three times.\
  144.  
  145. \fs16 \
  146. \
  147.  
  148. {{\NeXTGraphic3890 tune_mount_options.tiff \width10780 \height8040
  149. }
  150. ‹}\pard\tx7500\tx9520\f2\b0\i0\ulnone\fs16\fc0\cf0 \
  151. \
  152.  
  153. \pard\tx100\f0\b\fs24\fc0\cf0 Figure 2:  
  154. \f2\b0\i Using NFS Manager to set NFS parameters\
  155.  
  156. \pard\tx7500\tx9520\i0\fs16\fc0\cf0 \
  157.  
  158. \pard\tx7660\tx9660\f0\b\i\fc0\cf0 \
  159.  
  160. \fs24 Rules of thumb\
  161.  
  162. \fs16 \
  163.  
  164. \pard\tx7500\tx9520\f2\b0\i0\fs28\fc0\cf0 Normally you should specify the 
  165. \b bg
  166. \b0  option, so your system can retry mount requests in the background. Use the 
  167. \b fg
  168. \b0  option if the mount provides applications or data that the client needs to operate. \
  169.  
  170. \fs16 \
  171.  
  172. \fs28 The default values for 
  173. \b mnttimeo
  174. \b0  and 
  175. \b retry
  176. \b0  are normally fine. If the client accesses the server across a slow line—like a 56K-baud line or SLIP connection—or is overloaded, you can increase 
  177. \b mnttimeo
  178. \b0  or 
  179. \b retry
  180. \b0  to give the client a better chance of succeeding. Waiting longer for the server to respond doesn't cause big problems if the mount request is in the background. However, don't set these values higher than about 60 seconds—if the server doesn't respond in that time it's probably down and the client may as well give up the request. \
  181.  
  182. \fs16 \
  183.  
  184. \f0\b \
  185.  
  186. \fs28 NFS client/server communication\
  187.  
  188. \fs16 \
  189.  
  190. \f2\b0\fs28 Once a directory is mounted, a different set of parameters takes effect. They determine how the client and server communicate. The parameters you can set are listed in Figure 3.\
  191. \
  192.  
  193. \pard\tx2160\tx9520\f0\b\fs24\fi-1800\li2160\fc1\cf1 Parameter    Use\
  194. rsize
  195. \b0      Sets the size of the buffer for reading data from the server. Default is 8192 bytes.\
  196.  
  197. \pard\tx7500\tx9520\f2\fs16\fc0\cf0 \
  198.  
  199. \pard\tx2160\tx9520\f0\b\fs24\fi-1800\li2160\fc1\cf1 wsize
  200. \b0      Sets the size of the buffer for writing data to the server. Default is 8192 bytes.\
  201.  
  202. \pard\tx7500\tx9520\f2\fs16\fc0\cf0 \
  203.  
  204. \pard\tx2160\tx9520\f0\b\fs24\fi-1800\li2160\fc1\cf1 timeo
  205. \b0      Determines how long the client waits after making an NFS request before retransmitting the request. If there is no response after this time, the client multiplies 
  206. \b timeo
  207. \b0  by 2, waits that long, and retransmits. Default is 7 tenths of a second.\
  208.  
  209. \pard\tx7500\tx9520\f2\fs16\fc0\cf0 \
  210.  
  211. \pard\tx2160\tx9520\f0\b\fs24\fi-1800\li2160\fc1\cf1 retrans
  212. \b0      Determines how many times the client retransmits a request before a soft mount reports an error and gives up, or a hard mount reports an error and continues trying. Default is 3 times.\
  213.  
  214. \pard\tx7500\tx9520\f2\fs16\fc0\cf0 \
  215.  
  216. \pard\tx2160\tx9520\f0\b\fs24\fi-1800\li2160\fc1\cf1 soft
  217. \b0  or 
  218. \b hard
  219. \b0     Determines what a client should do if the server doesn't respond after the 
  220. \b retrans
  221. \b0  number is exceeded: Soft mounts give up, while hard mounts keep trying. Default is hard.\
  222.  
  223. \pard\tx7500\tx9520\f2\fs16\fc0\cf0 \
  224.  
  225. \pard\tx2160\tx9520\f0\b\fs24\fi-1800\li2160\fc1\cf1 rw
  226. \b0  or 
  227. \b ro
  228. \b0      Determines whether the server can both read and write (
  229. \b rw
  230. \b0 ) or read-only (
  231. \b ro
  232. \b0 ). Home directories and source code servers should be read-write so users can save their updates. LocalApps servers can be mounted read-only. Default is 
  233. \b rw
  234. \b0 .\
  235.  
  236. \pard\tx7500\tx9520\f2\fs16\fc0\cf0 \
  237.  
  238. \pard\tx2160\tx9520\f0\b\fs24\fi-1800\li2160\fc1\cf1 acregmin
  239. \b0      Sets the minimum time file entries remain cached, in seconds. Default is 3 seconds.\
  240.  
  241. \pard\tx7500\tx9520\f2\fs16\fc0\cf0 \
  242.  
  243. \pard\tx2160\tx9520\f0\b\fs24\fi-1800\li2160\fc1\cf1 acregmax
  244. \b0      Sets the maximum time file entries remain cached, in seconds. Default is 60 seconds.\
  245.  
  246. \pard\tx7500\tx9520\f2\fs16\fc0\cf0 \
  247.  
  248. \pard\tx2160\tx9520\f0\b\fs24\fi-1800\li2160\fc1\cf1 acdirmin
  249. \b0     Sets the minimum time directory entries stay cached, in seconds. Default is 30 seconds.\
  250.  
  251. \pard\tx7500\tx9520\f2\fs16\fc0\cf0 \
  252.  
  253. \pard\tx2160\tx9520\f0\b\fs24\fi-1800\li2160\fc1\cf1 acdirmax
  254. \b0     Sets the maximum time directory entries stay cached, in seconds. Default is 60 seconds.\
  255.  
  256. \pard\tx7500\tx9520\f2\fs16\fc0\cf0 \
  257.  
  258. \pard\tx2160\tx9520\f0\b\fs24\fi-1800\li2160\fc1\cf1 noac
  259. \b0     Turns file attribute caching off; omitting this parameter leaves caching on.\
  260.  
  261. \pard\tx7500\tx9520\f2\fs16\fc0\cf0 \
  262.  
  263. \pard\tx100\f0\b\fs24\fc0\cf0 Figure 3:  
  264. \f2\b0\i Parameters for tuning NFS communication\
  265.  
  266. \pard\tx7500\tx9520\i0\fs28\fc0\cf0 \
  267.  
  268. \fs16 \
  269.  
  270. \fs28 You set these parameters the same way you set the mount parameters. For example, Figure 2 also shows how to set communication parameters with NFS Manager.\
  271.  
  272. \fs16 \
  273.  
  274. \pard\tx7660\tx9660\f0\b\i\fc0\cf0 \
  275.  
  276. \fs24 Reading and writing\
  277.  
  278. \fs16 \
  279.  
  280. \pard\tx7500\tx9520\f2\b0\i0\fs28\fc0\cf0 The most important parameters are 
  281. \b rsize
  282. \b0  and 
  283. \b wsize
  284. \b0 . Set them to the largest sizes your network can handle with a minimum number of time-outs. Don't bother setting them higher than 8192—there's no added benefit.\
  285.  
  286. \fs16 \
  287.  
  288. \pard\tx7660\tx9660\f0\b\i\fc0\cf0 \
  289.  
  290. \fs24 Timing out and retrying\
  291.  
  292. \fs16 \
  293.  
  294. \pard\tx7500\tx9520\f2\b0\i0\fs28\fc0\cf0 Set 
  295. \b timeo
  296. \b0  to maximize efficiency when the server doesn't respond to a request. Setting it too high causes the client to wait too long to retransmit when a server drops a request, and therefore increases access times. Setting it too low may cause the client to retransmit when the server didn't drop a request but was just slow to respond. These unnecessary retransmit requests increase network traffic and slow things down even more. \
  297.  
  298. \fs16 \
  299.  
  300. \fs28 Setting 
  301. \b retrans
  302. \b0  can stop a client from hanging when a server of a read-only, soft-mounted partition fails. For hard mounts this parameter only determines when an “NFS server \
  303.  
  304. \i server_name
  305. \i0  not responding, still trying” message will be displayed. You don't normally need to change this parameter.   \
  306.  
  307. \fs16 \
  308. \
  309.  
  310. \pard\tx7660\tx9660\f0\b\i\fs24\fc0\cf0 Soft and hard mounts\
  311.  
  312. \fs16 \
  313.  
  314. \pard\tx7500\tx9520\f2\b0\i0\fs28\fc0\cf0 Always use the 
  315. \b hard
  316. \b0  parameter with read-write mounts. A server must be stateless, which means it has to be able to restart at any time. When it comes back up, it reestablishes communication with its clients, and continues where it left off. When a client writes to a server, the server always sends a reply saying that the data has been written to a non-volatile media, like a hard disk, so the client knows exactly which data was received successfully. Using the 
  317. \b hard
  318. \b0  setting ensures that the client of a failed server keeps trying until the server comes back up. After a server reestablishes communication, the client can continue where it left off with no data corruption. \
  319.  
  320. \fs16 \
  321.  
  322. \fs28 In contrast, if a server is mounted read-write with the 
  323. \b soft
  324. \b0  parameter and the server goes down while a client is writing data, the client can give up without finishing the write operation. This leaves the server with incomplete, corrupted data. \
  325.  
  326. \fs16 \
  327.  
  328. \pard\tx7660\tx9660\f0\b\i\fc0\cf0 \
  329.  
  330. \fs24 Attribute caching\
  331.  
  332. \fs16 \
  333.  
  334. \pard\tx7500\tx9520\f2\b0\i0\fs28\fc0\cf0 You can use the parameters 
  335. \b acregmin
  336. \b0 , 
  337. \b acregmax
  338. \b0 , 
  339. \b acdirmin
  340. \b0 , 
  341. \b acdirmax
  342. \b0 , and 
  343. \b noac
  344. \b0  to cache attributes of files and directories. The minimum and maximum parameters control whether the client caches directory entries about files and subdirectories, and how long information stays in the cache. Caching this data reduces the number of messages sent across the network. In addition, the mapped file system (MFS) interacts with NFS—if NFS is caching a file's attributes, MFS tries to keep pages of that file in memory as well. This improves performance further.\
  345.  
  346. \fs16 \
  347.  
  348. \fs28 You may notice the effects of read caching if you compile source code from an NFS server: The first compile you run is relatively slow compared to later compilations. This is because the header files are read in from the server and information about them is cached on the client. Since these files don't normally change between compilations, the information about them is held in the client's cache indefinitely, until it's swapped out to make room for other information.\
  349.  
  350. \fs16 \
  351.  
  352. \fs28 A side effect of caching is that a client may not always have the most recent information about a file. For example, if a user on one client computer changes a file on a server, a user on another client computer may not detect the change until the client's attribute caching time expires. If you're using an application that needs to know immediately when a remote file changes, use the 
  353. \b noac
  354. \b0  parameter to turn off caching.\
  355.  
  356. \fs16 \
  357.  
  358. \fs28 Another reason to set the 
  359. \b noac
  360. \b0  parameter is testing. For example, one of the tests described later in this article times a read request from the server. The data is read ten times and the average time is measured. If attribute caching had been turned on, the file's information would have been read just once from the server and cached on the client. So the next nine read requests would have gotten data not from the server but from the client's cache, giving incorrect test results.\
  361.  
  362. \fs16 \
  363.  
  364. \pard\f0\b\fc0\cf0 \
  365. \
  366. \
  367.  
  368. \fs48 Tuning tests \
  369.  
  370. \fs16 \
  371.  
  372. \pard\tx7500\tx9520\f2\b0\fs28\fc0\cf0 Three Ethernet adapters are now supported for NEXTSTEP for Intel Processors: The 3Com EtherLink
  373. \f3\fs20\up6 í 
  374. \f2\fs28\up0 III, SMC EtherCard PLUS Elite 16
  375. \f3\fs20\up6 î
  376. \f2\fs28\up0 , and Intel EtherExpress
  377. \f3\fs20\up6 î
  378. \f2\fs28\up0 . Each gives you a choice of external connector—BNC, AUI, or twisted pair. (Not all connectors are available on all adapters.) The type of external connection you use doesn't affect performance or tuning of NFS on the adapter, but each adapter has different levels of performance and must be tuned differently. \
  379.  
  380. \fs16 \
  381.  
  382. \fs28 I ran the adapters through two tests. The first was reading a one-megabyte file from an NFS server, with the Ethernet adapter in the client computer. The second test was writing a one-megabyte file to an NFS server, with the Ethernet adapter in the server. \
  383.  
  384. \fs16 \
  385.  
  386. \fs28 To perform the read or write I copied a file. I varied the values of the 
  387. \b rsize
  388. \b0 , 
  389. \b wsize
  390. \b0 , and 
  391. \b timeo
  392. \b0  parameters one at a time, measuring the time it took to read or write and the number of time-outs that occurred. I repeated each test ten times and took the average time as the result. The better performing adapter has shorter copy time and fewer timeouts. \
  393.  
  394. \fs16 \
  395.  
  396. \fs28 The PC I used was an ALR
  397. \f3\fs20\up6 í 
  398. \f2\fs28\up0 Evolution IV
  399. \f3\fs20\up6 î 
  400. \f2\fs28\up0 DX-2/166 EISA, with a Conner
  401. \f3\fs20\up6 í 
  402. \f2\fs28\up0 1.3-gigabyte disk and a DPT
  403. \f3\fs20\up6 í 
  404. \f2\fs28\up0 2022 SCSI controller with 4 megabytes of cache set for read and write caching. I used a 25-megahertz, 68040-based NeXTstation as the second system in all the tests. I also ran the tests between two 25-megahertz, 68040-based NeXTstation computers, to show the effects of changing the parameters for existing NeXT computers on a network.\
  405.  
  406. \fs16 \
  407.  
  408. \pard\f0\b\fc0\cf0 \
  409. \
  410. \
  411.  
  412. \fs48 3Com EtherLink III\
  413.  
  414. \fs16 \
  415.  
  416. \pard\tx7500\tx9520\f2\b0\fs28\fc0\cf0 This adapter has the smallest input buffer of the three: It's just two kilobytes. For this adapter, NFS read and write performance goes up and the number of time-outs drops dramatically when 
  417. \b rsize
  418. \b0  and 
  419. \b wsize
  420. \b0  are 1024 bytes. With larger values the buffer fills up and the adapter misses packets. Decreasing the values
  421. \b  
  422. \b0 further decreases performance while reducing time-outs only slightly, and so isn't worthwhile.\
  423.  
  424. \fs16 \
  425.  
  426. \fs28 \
  427.  
  428. {{\NeXTGraphic12536 3ComElink3_Rsize.eps \width3940 \height4460
  429. }
  430. ‹}\pard\tx7500\tx9520\f2\b0\i0\ulnone\fs28\fc0\cf0         
  431. {{\NeXTGraphic12545 3ComElink3_Wsize.eps \width3940 \height4460
  432. }
  433. ‹}\pard\tx7500\tx9520\f2\b0\i0\ulnone\fs28\fc0\cf0 \
  434.  
  435. \fs16 \
  436.  
  437. \pard\tx100\f0\b\fs24\fc0\cf0 Figure 4:  
  438. \f2\b0\i 3Com EtherLink III read test      
  439. \f0\b\i0 Figure 5:  
  440. \f2\b0\i 3Com EtherLink III write test\
  441.  
  442. \fs16 \
  443.  
  444. \pard\tx7500\tx9520\i0\fs28\fc0\cf0 Changing the 
  445. \b timeo
  446. \b0  value affects speed only if a significant number of time-outs occur, as the next two graphs show. I plotted the results of changing it only for this adapter, because it didn't affect other adapters.\
  447.  
  448. \fs16 \
  449.  
  450. \fs28 \
  451.  
  452. {{\NeXTGraphic12855 3ComElink3_Rtimeo.eps \width5980 \height4460
  453. }
  454. ‹}\pard\tx7500\tx9520\f2\b0\i0\ulnone\fs28\fc0\cf0  \
  455.  
  456. \fs16 \
  457.  
  458. \pard\tx100\f0\b\fs24\fc0\cf0 Figure 6:  
  459. \f2\b0\i 3Com EtherLink III read test, varying 
  460. \b timeo
  461. \b0 \
  462.  
  463. \pard\tx7500\tx9520\i0\fs16\fc0\cf0 \
  464.  
  465. \fs28 \
  466.  
  467. {{\NeXTGraphic12916 3ComElink3_Wtimeo.eps \width5960 \height4460
  468. }
  469. ‹}\pard\tx7500\tx9520\f2\b0\i0\ulnone\fs28\fc0\cf0  \
  470.  
  471. \fs16 \
  472.  
  473. \pard\tx100\f0\b\fs24\fc0\cf0 Figure 7:  
  474. \f2\b0\i 3Com EtherLink III write test, varying 
  475. \b timeo
  476. \b0 \
  477.  
  478. \pard\tx7500\tx9520\i0\fs16\fc0\cf0 \
  479.  
  480. \fs28 Reducing 
  481. \b timeo
  482. \b0  increases speed because a retransmit request is sent sooner for a dropped packet. With the default 
  483. \b timeo
  484. \b0  of 7, there are 13.2 time-outs and a write time of 24.8 seconds. By decreasing 
  485. \b timeo
  486. \b0  to 3, you get about the same number of time-outs, but the write speed increases almost 50 percent to 12.7 seconds. \
  487.  
  488. \fs16 \
  489.  
  490. \pard\f0\b\fc0\cf0 \
  491. \
  492. \
  493.  
  494. \fs48 SMC EtherCard PLUS Elite 16 \
  495.  
  496. \fs16 \
  497.  
  498. \pard\tx7500\tx9520\f2\b0\fs28\fc0\cf0 This is the mid-range adapter, with a larger receive buffer than the 3Com adapter. \
  499.  
  500. \fs16 \
  501.  
  502. \fs28 \
  503.  
  504. {{\NeXTGraphic13418 SMCeCard16_Rsize.eps \width3940 \height4460
  505. }
  506. ‹}\pard\tx7500\tx9520\f2\b0\i0\ulnone\fs28\fc0\cf0 \
  507.  
  508. \fs16 \
  509.  
  510. \pard\tx100\f0\b\fs24\fc0\cf0 Figure 8:  
  511. \f2\b0\i SMC EtherCard PLUS Elite 16 read test    \
  512.  
  513. \fs16 \
  514.  
  515. \pard\tx7500\tx9520\i0\fs28\fc0\cf0 The changes in read performance are small compared to those in write performance, as the next graph shows.\
  516.  
  517. \fs16 \
  518.  
  519. \fs28 \
  520.  
  521. {{\NeXTGraphic13581 SMCeCard16_Wsize.eps \width3940 \height4460
  522. }
  523. ‹}\pard\tx7500\tx9520\f2\b0\i0\ulnone\fs28\fc0\cf0 \
  524.  
  525. \fs16 \
  526.  
  527. \pard\tx100\f0\b\fs24\fc0\cf0 Figure 9:  
  528. \f2\b0\i SMC EtherCard PLUS Elite 16 write test\
  529.  
  530. \fs16 \
  531.  
  532. \pard\tx7500\tx9520\i0\fs28\fc0\cf0 An 
  533. \b rsize
  534. \b0  and 
  535. \b wsize
  536. \b0  of 4096 provide the best performance on this adapter. \
  537.  
  538. \fs16 \
  539.  
  540. \pard\f0\b\fc0\cf0 \
  541. \
  542. \
  543.  
  544. \fs48 Intel EtherExpress\
  545.  
  546. \fs16 \
  547.  
  548. \pard\tx7500\tx9520\f2\b0\fs28\fc0\cf0 This adapter has the largest receive buffer of the three and provides the best performance.\
  549.  
  550. \fs16 \
  551.  
  552. \fs28 \
  553.  
  554. {{\NeXTGraphic13827 IntelEtherExp_Rsize.eps \width3940 \height4460
  555. }
  556. ‹}\pard\tx7500\tx9520\f2\b0\i0\ulnone\fs28\fc0\cf0            
  557. {{\NeXTGraphic13839 IntelEtherExp_Wsize.eps \width3940 \height4460
  558. }
  559. ‹}\pard\tx7500\tx9520\f2\b0\i0\ulnone\fs28\fc0\cf0 \
  560.  
  561. \fs16 \
  562.  
  563. \pard\tx100\f0\b\fs24\fc0\cf0 Figure 10:  
  564. \f2\b0\i Intel EtherExpress read test         
  565. \f0\b\i0 Figure 11:  
  566. \f2\b0\i Intel EtherExpress write test\
  567.  
  568. \fs16 \
  569.  
  570. \pard\tx7500\tx9520\i0\fs28\fc0\cf0 The large buffer means there are no time-outs, no matter how you set the tuning parameters. Performance drops as 
  571. \b rsize
  572. \b0  and 
  573. \b wsize
  574. \b0  decrease, so keep them as large a possible.\
  575.  
  576. \fs16 \
  577.  
  578. \pard\f0\b\fc0\cf0 \
  579. \
  580. \
  581.  
  582. \fs48 NeXTstation\
  583.  
  584. \fs16 \
  585.  
  586. \pard\tx7500\tx9520\f2\b0\fs28\fc0\cf0 The data for a NeXTstation provide relative data and highlight some problems you may have in mixed networks. In particular, the NeXTstations slow as 
  587. \b rsize
  588. \b0  and 
  589. \b wsize
  590. \b0  decrease. If you're using NeXTstations as NFS servers and have 3Com EtherLink III adapters on the same network—or to a lesser extent, SMC EtherCard PLUS Elite 16 adapters—changing 
  591. \b rsize
  592. \b0  and 
  593. \b wsize
  594. \b0  will affect each adversely. \
  595.  
  596. \fs16 \
  597.  
  598. \fs28 \
  599.  
  600. \fs16 \
  601.  
  602. \fs28 \
  603.  
  604. {{\NeXTGraphic14518 NS040_Rsize.eps \width3920 \height4460
  605. }
  606. ‹}\pard\tx7500\tx9520\f2\b0\i0\ulnone\fs28\fc0\cf0       
  607. {{\NeXTGraphic14525 NS040_Wsize.eps \width3940 \height4460
  608. }
  609. ‹}\pard\tx7500\tx9520\f2\b0\i0\ulnone\fs28\fc0\cf0 \
  610.  
  611. \fs16 \
  612.  
  613. \pard\tx100\f0\b\fs24\fc0\cf0 Figure 12:  
  614. \f2\b0\i NeXTstation read test             
  615. \f0\b\i0  Figure 13:  
  616. \f2\b0\i NeXTstation write test\
  617.  
  618. \fs16 \
  619.  
  620. \pard\tx7500\tx9520\i0\fs28\fc0\cf0 Decreasing the buffer size to 1024 significantly reduces the performance of NeXTstations. Reducing 
  621. \b timeo
  622. \b0  can increase the speed of the 3Com adapter when setting 
  623. \b rsize
  624. \b0  and 
  625. \b wsize
  626. \b0  to 8192, which keeps the performance of the NeXTstations at its best. However, you will still have many time-outs—and therefore retransmissions—on your network. This will increase the network traffic and slow things down as network load goes up, and isn't the best solution.\
  627.  
  628. \fs16 \
  629.  
  630. \fs28 A better choice is to set 
  631. \b rsize
  632. \b0  and 
  633. \b wsize
  634. \b0  to 1024 for the computers using 3Com adapters. This reduces the number of time-outs and retransmissions on the network. The optimal but not necessarily most practical thing to do is to put the different hardware in different NetInfo domains, so you can use different NFS mount parameters. \
  635.  
  636. \fs16 \
  637.  
  638. \f0\b \
  639.  
  640. \fs28 Result summary\
  641.  
  642. \fs16 \
  643.  
  644. \f2\b0\fs28 For PC networking, the Intel EtherExpress adapter provides the best performance of the three currently compatible adapters, so it's the best choice for performance. \
  645.  
  646. \fs16 \
  647.  
  648. \fs28 If you must use a different adapter, you can still tune NFS to get optimal performance. \
  649.  
  650. \fs16 \
  651. \
  652.  
  653. \pard\tx3960\tx5400\tx6840\tx9520\f0\b\fs24\fi-1800\li2160\fc1\cf1 Adapter    wsize    rsize    timeo\
  654.  
  655. \b0 3Com EtherLink III    1024    1024    3\
  656.  
  657. \pard\tx100\f2\i\fs16\fc0\cf0 \
  658.  
  659. \pard\tx3960\tx5400\tx6840\tx9520\f0\i0\fs24\fi-1800\li2160\fc1\cf1 SMC EtherCard PLUS Elite16    4096    4096    -\
  660.  
  661. \pard\tx100\f2\i\fs16\fc0\cf0 \
  662.  
  663. \pard\tx3960\tx5400\tx6840\tx9520\f0\i0\fs24\fi-1800\li2160\fc1\cf1 Intel EtherExpress    8192    8192    -\
  664.  
  665. \pard\tx100\f2\i\fs16\fc0\cf0 \
  666.  
  667. \f0\b\i0\fs24 Figure 14:  
  668. \f2\i wsize
  669. \b0 ,
  670. \b  rsize
  671. \b0 , and
  672. \b  timeo 
  673. \b0 settings for highest performance\
  674.  
  675. \fs16 \
  676.  
  677. \pard\f0\b\i0\fc0\cf0 \
  678. \
  679. \
  680.  
  681. \fs48 Conclusions\
  682.  
  683. \fs16 \
  684.  
  685. \pard\tx7500\tx9520\f2\b0\fs28\fc0\cf0 In most cases, tuning NFS performance can make a big difference in overall network performance, and thereby in system usability. To fine-tune your system, you can run tests like these. Be sure to turn off caching while testing, so you get accurate results.\
  686.  
  687. \fs16 \
  688.  
  689. \fs28 Your Ethernet media also affect how you tune NFS parameters. In future articles I'll cover tuning NFS across T1 lines, 56K-baud lines, routers, and SLIP connections. 
  690. \fs20 n\
  691. \
  692.  
  693. \fs16 \
  694.  
  695. \i\fs24 Wayde Schroeder is a Premium Support Engineer. He's been at NeXT for three years. You can reach him by e-mail at 
  696. \b Wayde_Schroeder@next.com
  697. \b0 .\
  698.  
  699. \fs16 \
  700.  
  701. }
  702.